<?php defined('SYSPATH') OR die('No direct access allowed.'); ?>
<!DOCTYPE html>
<html lang='en' xmlns:fb='http://www.facebook.com/2008/fbml' xmlns:groupon='http://groupon.com/ns/#' xmlns='http://www.w3.org/1999/xhtml'>
<head>
<title><?php echo html::specialchars($title) ?></title>
<meta content='text/html;charset=utf-8' http-equiv='Content-Type' />
<link href="/stylesheets/base.css" media="screen" rel="stylesheet" type="text/css" />
<link href="/stylesheets/app/invite/controller.css" media="screen" rel="stylesheet" type="text/css" />
<link href="/stylesheets/app/invite/index.css" media="screen" rel="stylesheet" type="text/css" />
<script type="text/javascript">var Groupon = {};</script>
<script type='text/javascript'> 
  //<![CDATA[
	Finch = {
  
	  onReady : function(f) {
		this.onReadyFunctions = this.onReadyFunctions || [];
		this.onReadyFunctions.push(f);
	  },
  
	  execute : function() {
		if (!this.onReadyFunctions) return;
		for (i=0; i<this.onReadyFunctions.length; i++){
		  this.onReadyFunctions[i].call();
		}
	  }
	};
  //]]>
</script>
<!-- / normal non-cached rails mode -->
<script type='text/javascript'> 
  //<![CDATA[
	Groupon.currentUser = {};
	Groupon.currentUser.isAuthenticated = false;
  //]]>
</script>
<script type='text/javascript'> 
  //<![CDATA[
	Groupon.cdnCacheable = false;
  //]]>
</script>
<script type='text/javascript'> 
  //<![CDATA[
	var _groanalytics = _groanalytics || [];
  //]]>
</script>
<script type='text/javascript'> 
  //<![CDATA[
	//Chartbeat
	var _sf_startpt=(new Date()).getTime();
  //]]>
</script>
</head>
<body class='js_enabled'>
<div class='clearfix default' id='global_container'>
  <?php 
	echo $header;
	echo $content;
	echo $footer; 
?>
</div>

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js" type="text/javascript"></script>
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.10/jquery-ui.min.js" type="text/javascript"></script>
<script src="/javascripts/dev/jquery.validate.js" type="text/javascript"></script>
<script type='text/javascript'> 
      //<![CDATA[
        Groupon.onCurrentUserReady = function(callback){
          if (Groupon.currentUser !== undefined ) {
            return callback();
          };
          $(document).bind('currentUserReady', function(){
            return callback();
          });
        };
        Groupon.onFacebookReady = function(callback){
          if (Groupon.facebookReady !== undefined ) {
            return callback();
          };
          $(document).bind('facebookReady', function(){
            return callback();
          });
        };
      //]]>
    </script>
<script src="http://assets1.grouponcdn.com/assets/application.js?vWI8k_br" type="text/javascript"></script>
<script type="text/javascript"> 
//<![CDATA[
Groupon.Application.setDivision("chicago");
 
//]]>
</script>
<script type='text/javascript'> 
      //<![CDATA[
        Groupon.onCurrentUserReady(function(){
          if (Groupon.currentUser.isAuthenticated) {
            Groupon.Application.setLoggedIn();
          }
          if (Groupon.currentUser.isAuthenticated && !Groupon.currentUser.subscribedToCurrentDivision) {
            Groupon.Subscription.setAutoSubscribe(Groupon.currentUser.emailAddress);
          }
        });
      //]]>
    </script>
<!--[if IE 6]>
      <script src="http://assets1.grouponcdn.com/assets/ie6.js?hVsiI_b8" type="text/javascript"></script>
    <![endif]-->
<script src="http://assets1.grouponcdn.com/assets/facebook.js?K2umkWBs" type="text/javascript"></script>
<script type='text/javascript'> 
      //<![CDATA[
        Groupon.facebookApiKey = "ddb107c4c50eca3b5705114a7d573cb8";
        Groupon.onCurrentUserReady(function() {
          if(window.FB) {
            Groupon.Facebook.init();
            $("#fb-root").fire("facebook:loaded");
            Groupon.facebookReady = true;
            $.event.trigger('facebookReady');
          } else {
            window.fbAsyncInit = function() {
              Groupon.Facebook.init();
              $("#fb-root").fire("facebook:loaded");
              Groupon.facebookReady = true;
              $.event.trigger('facebookReady');
            };
          }
          if (Groupon.currentUser.isAuthenticated && Groupon.currentUser.connectedWithFacebook) {
            Groupon.Application.setConnectedWithFacebook();
          };
          if (Groupon.currentUser.isAuthenticated) {
            $(".facebook_widget").remove();
          };
        });
      //]]>
    </script>
<script type='text/javascript'> 
      var gaJsHost = (("https:" == document.location.protocol) ? " https://ssl." : "http://www.");
      document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
    </script>
<script type='text/javascript'> 
      try{
      var pageTracker = _gat._getTracker("UA-1250257-1");
      pageTracker._setDomainName(".groupon.com");
      }catch(err){}
    </script>
<script type='text/javascript'> 
      if(window.google_goal){
      pageTracker._trackPageview(google_goal);
      pageTracker._addTrans(
      google_order_id,"",
      google_amount,"","","","","");
      pageTracker._addItem(
      google_order_id,
      google_sku,
      google_product_name,
      "Uncategorized",
      google_unit_price,
      google_quantity
      );
      pageTracker._trackTrans();
      } else {
      pageTracker._trackPageview();
      }
    </script>
<div class='inserted_tracking_container' style='display: none'>
  <script type="text/javascript"> 
      var _sf_async_config={uid:410,domain:"groupon.com"};
      (function(){
      function loadChartbeat() {
      window._sf_endpt=(new Date()).getTime();
      var e = document.createElement('script');
      e.setAttribute('language', 'javascript');
      e.setAttribute('type', 'text/javascript');
      e.setAttribute('src',
      (("https:" == document.location.protocol) ? "https://s3.amazonaws.com/" : "http://") +
      "static.chartbeat.com/js/chartbeat.js");
      document.body.appendChild(e);
      }
      var oldonload = window.onload;
      window.onload = (typeof window.onload != 'function') ?
      loadChartbeat : function() { oldonload(); loadChartbeat(); };
      })();
      </script>
</div>
<script type='text/javascript'> 
      //<![CDATA[
        Event.onReady(function(ev){
        
      
          if(typeof(Finch) != "undefined")
            Finch.execute();
        });
      //]]>
    </script>
</body>
</html>

